<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <link href="__CSS__/bootstrap.min.css" rel="stylesheet">
    <link href="__CSS__/repair.css" rel="stylesheet">
    <title>维修完成</title>
</head>
<body>
<div class="container">
    <div class="row">
        <div class="col-md-12">
                <fieldset>
                    <legend>维修完成</legend>
                    <div class="form-group">
                        <label class="control-label col-md-2">设备名称</label>
                        <span id="result-equip-name" class="text-left col-md-10">
                            <?php 
                                $devicename = $allmsgs['0'];
                                $len =  strlen($devicename);
                                if($len>30){
                                  echo mb_substr($devicename,0,30)."..."; 
                                }else{
                                  echo $devicename; 
                                }                                
                            ?>
                        </span>
                    </div>
                    <div class="form-group">
                        <label class="control-label col-md-2">报修时间</label>
                        <span id="result-date" class="text-left col-md-10">
                          <?php echo $allmsgs['1'];?>
                        </span>
                    </div>
                    <div class="form-group">
                        <label class="control-label col-md-2">设备型号</label>
                        <span id="result-equip-id" class="text-left col-md-10"><?php echo $allmsgs['2'];?></span>
                    </div>
                    <div class="form-group">
                        <label class="control-label col-md-2">更换部件</label>
                        <span id="result-componentsName" class="col-md-10">
                          <?php 
                            if($allmsgs['3']==""){
                              echo "否";
                            }else{
                              echo $allmsgs['3'];
                            }
                          ?>
                        </span>
                    </div>
                    <div class="form-group">
                        <label class="control-label col-md-2">故障描述</label>
                        <div class="col-md-10">
                            <textarea disabled id="result-describe" name="describe" class="form-control" rows="3" placeholder="请输入故障详情"><?php echo trim($allmsgs['4']);?></textarea>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="control-label col-md-2">附件图片</label>
                        <div class="col-md-10">
                            <div class="col-md-10">
                                <?php 
                                    $url = $allmsgs['5'];
                                    if($url){
                                    ?>
                                      <button class="btn btn_primary" id="previewImage">
                                      <img src="<?php echo $url;?>" />
                                      </button>
                                    <?php
                                    }else{
                                      echo "没有图片哦";  
                                    }
                                ?>
                            </div>
                        </div>
                    </div>
                    <p class="bg-primary text-center">维修完成</p>
                </fieldset>
        </div>
    </div>
</div>
</body>
<script src="__JS__/jquery.min.js"></script>
<script src="__JS__/bootstrap.min.js"></script>
<script src="__JS__/repair.js"></script>
<script src="http://res.wx.qq.com/open/js/jweixin-1.0.0.js"> </script>
</html>